Skip to content

docs(historical): moby/client SDK migration notes#264

Merged
JoshuaAFerguson merged 1 commit into
mainfrom
docs/moby-client-migration-notes
Apr 25, 2026
Merged

docs(historical): moby/client SDK migration notes#264
JoshuaAFerguson merged 1 commit into
mainfrom
docs/moby-client-migration-notes

Conversation

@JoshuaAFerguson

Copy link
Copy Markdown
Member

Summary

Captures the scope of the deferred github.com/docker/dockergithub.com/moby/moby/client migration so the next person picking it up has a starting point. No code changes — this is a notes-only PR.

Context

We pin github.com/docker/docker v28.5.2+incompatible today (PR #257). The upstream Go module path was deprecated and reorganized:

  • github.com/moby/moby/v2 — root module (currently v2.0.0-betaN)
  • github.com/moby/moby/api — split-out API types (v1.54.x)
  • github.com/moby/moby/client — standalone client SDK (v0.4.x)

I attempted the migration in this session, scoped it carefully, and pulled back rather than ship a half-done refactor. The notes capture what I learned.

What's covered

  • Why the upstream module path moved (moby reorganization, docker-vX tag prefix vs semver, why a naive go get for v29 fails)
  • Current pin still works — this is scope, not a correctness bug
  • Module import mapping table (old → new for every package we use)
  • Call-signature changes by API method: ContainerCreate, ContainerInspect, ServiceInspectWithRawServiceInspect, ServiceUpdate, TaskList, filters
  • Call-site inventory with file paths and counts (~20–25 sites across agents/docker-agent/)
  • Suggested approach (drop the umbrella module to avoid ambiguous imports, search-replace, let the compiler walk through the call-site fixes)

Allow ~1.5–3 h of careful work for the migration itself.

Capture the scope of the deferred github.com/docker/docker ->
github.com/moby/moby/client migration so the next person picking it
up has a starting point.

Covers:
- Why the upstream module path moved (moby reorganization, docker-vX
  tag prefix vs semver, why naive go get fails on v29)
- Current pin (docker v28.5.2 still works; this is scope, not bug)
- Module import mapping table
- Call-signature changes by API method (ContainerCreate, Inspect,
  ServiceInspect, ServiceUpdate, TaskList, filters)
- Call-site inventory with file paths
- Suggested approach

No code changes.
@JoshuaAFerguson JoshuaAFerguson merged commit a670386 into main Apr 25, 2026
@JoshuaAFerguson JoshuaAFerguson deleted the docs/moby-client-migration-notes branch April 25, 2026 23:23
@github-actions github-actions Bot added the documentation Improvements or additions to documentation label Apr 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant